# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=bmap
pkgver=1.0.17
pkgrel=1
groups=('blackarch' 'blackarch-forensic')
pkgdesc="A tool that can store data in slackspace on any filesystem. It can detect used slackspace and recover the data."
url='http://www.securityfocus.com/tools/1359'
arch=('x86_64')
license=('GPL2')
makedepends=('linuxdoc-tools')
source=("http://www.hacker-soft.net/tools/Miscellaneous/$pkgname-$pkgver.tar.gz")
sha512sums=('503aa24ee3f03387d97bf69b8d22da2b759617fc1a8c7cf03f33ea87b1002a8534c64d0bb5fddca3a324fa6db773b2f83d1d2e5930594a08b00774e947a551d2')

prepare() {
  cd "$pkgname-$pkgver"

  sed -i 's|BINDIR = "[^"]*"|BINDIR = $(DESTDIR)/usr/bin|;
          s|MANDIR = "[^"]*"|MANDIR = $(DESTDIR)/usr/share/man|' Makefile
}

build() {
  cd "$pkgname-$pkgver"

  make
}

package() {
  cd "$pkgname-$pkgver"

  install -dm 755 "$pkgdir/usr/bin" "$pkgdir/usr/share/man/man1"

  make DESTDIR="$pkgdir" install
}

